<?php if (!defined('THINK_PATH')) exit(); /*a:3:{s:64:"C:\wamp200\www\xgwnew/application/index\view\index\neworder.html";i:1551425879;s:61:"C:\wamp200\www\xgwnew/application/index\view\public\base.html";i:1547453452;s:69:"C:\wamp200\www\xgwnew/application/index\view\public\previewimage.html";i:1533868924;}*/ ?>
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1,maximum-scale=1,user-scalable=no">
<meta name="apple-mobile-web-app-capable" content="yes">
<meta name="apple-mobile-web-app-status-bar-style" content="black">
<title><?php echo $title; ?></title>
<link rel="stylesheet" href="__PUBLIC__/xsd/css/mui.min.css">
<link rel="stylesheet" type="text/css" href="__PUBLIC__/xsd/css/icons-extra.css" />
<link rel="stylesheet" type="text/css" href="__PUBLIC__/xsd/css/app.css?v1111121" />
<link rel="stylesheet" type="text/css" href="__PUBLIC__/css/bootstrap/bootstrap.min.css"/>

</head>
<!--/head-->
<body>
	<script src="__PUBLIC__/js/jquery.js"></script>
<script src="http://res.wx.qq.com/open/js/jweixin-1.2.0.js" charset="utf-8"></script>
    <script type="text/javascript" src="https://apis.map.qq.com/tools/geolocation/min?key=QQ6BZ-24HC6-ZAXSZ-MTZAU-5MU2J-HEFEH&referer=鲜果屋"></script>
<script>
//alert("cc");
		  var geolocation = new qq.maps.Geolocation();
     var options = {timeout: 9000};
        var positionNum = 0;
	geolocation.getLocation(showPosition, showErr, options);
	
	function showPosition(position) {
		
            positionNum ++;
            document.getElementById("demo").innerHTML += "序号：" + positionNum;
            document.getElementById("demo").appendChild(document.createElement('pre')).innerHTML = JSON.stringify(position, null, 4);
            document.getElementById("pos-area").scrollTop = document.getElementById("pos-area").scrollHeight;
        };
 
        function showErr() {
            positionNum ++;
            document.getElementById("demo").innerHTML += "序号：" + positionNum;
            document.getElementById("demo").appendChild(document.createElement('p')).innerHTML = "定位失败！";
            document.getElementById("pos-area").scrollTop = document.getElementById("pos-area").scrollHeight;
        };

	
</script>

	<!--/header-->


<style>

.mui-table-view-cell p {

    margin-bottom: 0;

    font-size: 12px;

}

.mui-table-view .mui-media-object {

    line-height: 42px;

    width: 60px !important;

        max-width: 60px;

    height: 60px;

}

.mui-card-header {

    font-size: 12px;

    border-radius: 2px 2px 0 0;

        padding: 5px 10px;

}

</style>
<textarea id="foo2"  cols="40" wrap="hard" style="     height: 10px;  margin-left: -1000px;margin-bottom: 0;"  >  
	团购清单 :   <?php if(is_array($listyouji) || $listyouji instanceof \think\Collection): $k = 0; $__LIST__ = $listyouji;if( count($__LIST__)==0 ) : echo "" ;else: foreach($__LIST__ as $key=>$vo): $mod = ($k % 2 );++$k;?>     
	订单<?php echo $k; ?>-    <?php echo $vo['remark']; ?> 
	<?php echo $vo['fhremark']; endforeach; endif; else: echo "" ;endif; ?>     
	      </textarea>
	<textarea id="foo"  cols="40" wrap="hard" style="     height: 10px;  margin-left: -1000px;margin-bottom: 0;"  >  
	团购清单 :   <?php if(is_array($listxiaoge) || $listxiaoge instanceof \think\Collection): $k = 0; $__LIST__ = $listxiaoge;if( count($__LIST__)==0 ) : echo "" ;else: foreach($__LIST__ as $key=>$vo): $mod = ($k % 2 );++$k;?>     
	订单<?php echo $k; ?>-    <?php echo $vo['remark']; ?>   
	<?php echo $vo['fhremark']; endforeach; endif; else: echo "" ;endif; ?>     
	      </textarea>

<header class="mui-bar mui-bar-nav">

  <!-- <a class="mui-action-back mui-icon mui-icon-left-nav mui-pull-left"></a> -->

  <h1 class="mui-title">最新订单</h1>

</header>

<div class="mui-content" style="    margin-bottom: 100px;">
			<div>
			<form method="get">
				<div>
					备注|地址|名字：<input type="text" class="form-control" name="remarkbak" value="<?php echo $_GET['remarkbak']; ?>" placeholder="请输入地址/备注/名字">
				
				开始时间：<input type="date" class="form-control" name="start" value="<?php echo $_GET['start']; ?>" placeholder="瀵拷婵妞傞梻锟�">
										
						结束时间：<input type="date" class="form-control" name="end" value="<?php echo $_GET['end']; ?>" placeholder="缂佹挻娼弮鍫曟？">
											
					<input type="radio" name="buystatus" value="1">已发货
                    <input type="radio" name="buystatus" value="2">未发货
				    <input type="radio" name="buystatus" value="3">全部
				
              
					 <button class="btn btn-primary" type="submit">搜索</button>
				</div>
			
			</form>
		</div>
		<script src="__PUBLIC__/xsd/js/clipboard.min.js"></script>
		     <!--<textarea id="foo2"  style="     height: 10px;  margin-left: -1000px;margin-bottom: 0;"  >
      &#13订单号
    
    </textarea>
		订单复制-->
		 <button class="btn " data-clipboard-target="#foo2" aria-label="复制成功！" style="margin: 0 auto;display: block;">邮寄订单复制</button><br />
		 <button class="btn " data-clipboard-target="#foo" aria-label="复制成功！" style="margin: 0 auto;display: block;">小哥订单复制</button><br />
		   <script>
    //new Clipboard('.btn');
    var clipboard = new Clipboard('.btn');

    clipboard.on('success', function(e) {
    	var msg = e.trigger.getAttribute('aria-label');
      console.log(e);
    	alert(msg);

        e.clearSelection();
    });
    </script>
    
			<div>
	<span>商品总价格(<?php echo $shopsSum; ?>)</span>
           <span>代理价额(<?php echo $dlpritotalSum; ?>)</span>
           
         
          
      </div>

      

  <?php if(is_array($list) || $list instanceof \think\Collection): $i = 0; $__LIST__ = $list;if( count($__LIST__)==0 ) : echo "" ;else: foreach($__LIST__ as $key=>$vo): $mod = ($i % 2 );++$i;?>

    <div class="mui-card">

      	<div class="mui-card-header ">

          <!--<div class="mui-ellipsis mui-col-xs-8">订单编号：<?php echo $vo['out_trade_no']; ?></div>-->
          <div class="mui-ellipsis mui-col-xs-8">订单编号：<?php echo $vo['id']; ?></div>
          <!--小哥单-->
          <?php if($vo['fhway'] == 1): ?>
          <div class="mui-ellipsis mui-col-xs-8" style='color:red'>邮寄订单</div>
          <?php elseif($vo['fhway'] == 2): ?>
           <div class="mui-ellipsis mui-col-xs-8" style='color:red'>小哥订单</div>
            <?php elseif($vo['fhway'] == 3): ?>
           <div class="mui-ellipsis mui-col-xs-8" style='color:red'>预定订单</div>
           <?php endif; if($vo['buystatus'] == '1'): ?>
<!--<div class="mui-col-xs-4 mui-text-right"><a href="<?php echo url('index/order/shipments',array('id'=>$vo['id'],'note'=>1)); ?>" onclick="if(confirm('确定发货?')==false)return false;" class="confirm ajax-get">发货</a></div>-->
<div class="mui-col-xs-4 mui-text-right"><a href="javascript:;" data-toggle="modal" data-target="#myModal2" data-id="<?php echo $vo['id']; ?>" >发货</a></div>
<?php endif; if($vo['buystatus'] == '3'): ?>
<div class="mui-col-xs-4 mui-text-right" style='color:red'><?php echo $vo['name']; ?>已发货</div>
 <?php endif; ?>
         <!-- 根据状态显示发货未发货
          <div class="mui-col-xs-4 mui-text-right"><button  type="button" class="mui-btn qxdd mui-btn-primary mui-btn-outlined" style="font-size:12px;"><?php echo parse_config_value($vo['buystatus'],'pay_status'); ?></button></div>

<div class="mui-col-xs-4 mui-text-right"><a href="javascript:;" data-toggle="modal" data-target="#myModa99" data-id="<?php echo $vo['id']; ?>" >拍订单号</a></div>

-->	 



        </div>

      	<div class="mui-card-content">

      		<div class="mui-card-content-inner" style="    padding: 5px 0;">



            <ul class="mui-table-view mui-table-view-chevron">
            	
            	

<!--
            	     	<li class="mui-table-view-cell mui-media">
            		
<div>
<div id="thelist<?php echo $vo['id']; ?>" class="mui-media-object mui-pull-left"></div>
   	  	
 <div class="btns col-sm-2">
  <div class="picker">选择文件</div>
  <button id="ctlBtn" class="btn default-btn" data-bhid="<?php echo $vo['id']; ?>" >开始上传</button>
 </div>
</div>
  </li>
     -->     
         
            	<li class="mui-table-view-cell mui-media">
            		


  订单图片：<img class="mui-media-object" src="<?php echo get_cover($vo['ddimage'],'path','400x218'); ?>" data-preview-src="" data-preview-group="<?php echo $vo['ddimage']; ?>">
</li>
<!--
	
-->

<li class="mui-table-view-cell mui-media" onclick='window.location.href = "<?php echo url('index/order/detail',array('id'=>$vo['id'])); ?>"'>

                       
                    <a class="mui-navigate-right">

                        
                        <div class="mui-media-body">

                            <div>
                            	
                            	<strong>
                                <!--¥<?php echo $vo['total']; ?>&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp运费：¥<?php echo $vo['yunfei']; ?></br>-->
                            	
                            	配送备注：<?php echo $vo['fhremark']; ?></br>
                            	<?php if($vo['fh_time'] > 0): ?>                            	
                            	发货时间：<?php echo date("Y/m/d H:i",$vo['fh_time']); else: ?>
                            	发货时间：
                            	<?php endif; ?>
                            	<p>下单时间：<?php echo $vo['create_time']; ?></p>
                            	</strong>
                            </div>

                            

                            <!--<p>收货时间：<?php echo $vo['group_time']; ?> <?php echo $vo['deliverytime']; ?>-->
                            	
                            </p>
<!--
                            <p>订单类型：

                              <?php if($vo['index_type'] == '1'): ?>

                                  团购

                              <?php endif; if($vo['index_type'] == '0'): ?>

                                及时配送

                              <?php endif; ?>

                            </p>

                            <p>收货人：<?php echo $vo['user_name']; ?>   <br /> 
                            	收货地址：<?php echo $vo['address']; ?>   <br />
                            	微信：<?php echo $vo['nick_name']; ?>

                            </p>
                           -->  

                           
                            <textarea style="font-size:10px" rows="3"><?php echo $vo['remark']; ?></textarea>

                        </div>

                    </a>

                </li>



            </ul>





        	</div>

      </div>

    </div>

  <?php endforeach; endif; else: echo "" ;endif; ?>

  <?php echo $list->muirender(); ?>
  
 <div class="modal fade "  id="myModal2" tabindex="-1" role="dialog" aria-labelledby="myModalLabel" aria-hidden="true">
        <div class="modal-dialog modal-sm">
          <div class="modal-content">
            <div class="modal-header">
              <button type="button" class="close" data-dismiss="modal"><span aria-hidden="true">&times;</span><span class="sr-only">Close</span></button>
              <h4 class="modal-title" id="myModalLabel">运费详细情况</h4>
            </div>
						<form class="form-horizontal2" action="<?php echo url('index/order/shipmentstest'); ?>" method="post">
	            <div class="modal-body">
	              <div>运费金额：<input type="text" name="yunfei" class="form-control" value="0" style=" width: 60px;text-align: center;" /></div>
								<div>
									<span>运费说明：</span>
									<textarea name="yunfeidetail" class="form-control"></textarea>
								</div>
													<input type="hidden" name="id" value="">
	            </div>
	            <div class="modal-footer">
	              <button type="button" class="btn btn-default" data-dismiss="modal">关闭</button>
	              <button type="submit" class="btn btn-primary submit-btn ajax-post"  target-form="form-horizontal2">确定</button>
	            </div>
						</form>
          </div>
        </div>
      </div>
			<script>
			 $(function(){
				 $('#myModal2').on('show.bs.modal', function (e) {
				 	
						var id = $(e.relatedTarget.outerHTML).attr('data-id');
						$(e.target).find('[name="id"]').val(id);
						
						
				 })
			 })
			</script>
			
			
	<!--引入CSS-->
<link rel="stylesheet" type="text/css" href="__PUBLIC__/plugs/webuploader-0.1.5/webuploader.css">

<!--引入JS-->
<script type="text/javascript" src="__PUBLIC__/plugs/webuploader-0.1.5/webuploader.js"></script>
		
	<div class="modal fade "  id="myModa99" tabindex="-1" role="dialog" aria-labelledby="myModalLabel" aria-hidden="true">
       
          
 <!--用来存放文件信息
 <div id="thelist" class="uploader-list col-sm-10"></div>
 -->
 
</div>

       
        <div class="modal-dialog modal-sm">
          <div class="modal-content">
            <div class="modal-header">
              <button type="button" class="close" data-dismiss="modal"><span aria-hidden="true">&times;</span><span class="sr-only">Close</span></button>
              <h4 class="modal-title" id="myModalLabel">拍订单号</h4>
            </div>
            
                    
 <!--用来存放文件信息
 <div id="thelist" class="uploader-list col-sm-10"></div>
 -->
</div>


						<form class="form-horizontal2" action="<?php echo url('index/goodshops/testimage'); ?>" method="post">
	            <div class="modal-body">

	            
	            	
				<input type="hidden" name="id" value="">
	            </div>
	            <div class="modal-footer">
	              <button type="button" class="btn btn-default" data-dismiss="modal">关闭</button>
	              <button type="submit" class="btn btn-primary submit-btn ajax-post"  target-form="form-horizontal2">确定</button>
	            </div>
						</form>
          </div>
        </div>
      </div>
			<script>
			 $(function(){
				 $('#myModa99').on('show.bs.modal', function (e) {
				 	
						var id = $(e.relatedTarget.outerHTML).attr('data-id');
						$(e.target).find('[name="id"]').val(id);
						
						
				 })
			 })
			</script>
	
</div>






<!--/#footer-->



<script src="__PUBLIC__/js/bootstrap.js"></script>
<script src="__PUBLIC__/js/jquery.nanoscroller.min.js"></script>
<script src="__PUBLIC__/xsd/js/mui.min.js"></script>
<script src="__PUBLIC__/xsd/js/flexible.js"></script>
<script src="__PUBLIC__/xsd/js/template.js"></script>


<!--
<script type="text/javascript">
	
	   $(function(){
 
    $('.qxdd').on('tap', function(){

    	 var valid =   $("#orderid").val();
    	 var url = $(this).attr('data-url')
     var btnArray = ['鍚�', '鏄�'];
     mui.confirm('鎮ㄧ‘瀹氬凡缁忓彂璐т簡鍚楋紵', '纭畾鍙戣揣', btnArray, function(e) {
       if (e.index == 1) {
           $.post("<?php echo url('index/order/shipments'); ?>", {'id': valid, 'note': 0}, function(data) {
               
               
               if(data.code == 1){
				mui.toast('鍙戣揣鎴愬姛锛�')
               setTimeout(function() {
                 return ;
               }, 2000);
               
			}
			
			
           }, "json");

       } else {
       	mui.toast('鍙戣揣aaaaabbbcc鎴愬姛锛�')
         return ;
       }
     })
     
     
     




    })


    })

	
	
</script>-->

<script>

  mui.init({

    swipeBack:true //启用右滑关闭功能

  });

  $('#scroll').height($(window).height()-44)



</script>
<style type="text/css">
  .mui-preview-image.mui-fullscreen {
    position: fixed;
    z-index: 20;
    background-color: #000;
  }

  .mui-preview-header,
  .mui-preview-footer {
    position: absolute;
    width: 100%;
    left: 0;
    z-index: 10;
  }

  .mui-preview-header {
    height: 44px;
    top: 0;
  }

  .mui-preview-footer {
    height: 50px;
    bottom: 0px;
  }

  .mui-preview-header .mui-preview-indicator {
    display: block;
    line-height: 25px;
    color: #fff;
    text-align: center;
    margin: 15px auto 4;
    width: 70px;
    background-color: rgba(0, 0, 0, 0.4);
    border-radius: 12px;
    font-size: 16px;
  }

  .mui-preview-image {
    display: none;
    -webkit-animation-duration: 0.5s;
    animation-duration: 0.5s;
    -webkit-animation-fill-mode: both;
    animation-fill-mode: both;
  }

  .mui-preview-image.mui-preview-in {
    -webkit-animation-name: fadeIn;
    animation-name: fadeIn;
  }

  .mui-preview-image.mui-preview-out {
    background: none;
    -webkit-animation-name: fadeOut;
    animation-name: fadeOut;
  }

  .mui-preview-image.mui-preview-out .mui-preview-header,
  .mui-preview-image.mui-preview-out .mui-preview-footer {
    display: none;
  }

  .mui-zoom-scroller {
    position: absolute;
    display: -webkit-box;
    display: -webkit-flex;
    display: flex;
    -webkit-box-align: center;
    -webkit-align-items: center;
    align-items: center;
    -webkit-box-pack: center;
    -webkit-justify-content: center;
    justify-content: center;
    left: 0;
    right: 0;
    bottom: 0;
    top: 0;
    width: 100%;
    height: 100%;
    margin: 0;
    -webkit-backface-visibility: hidden;
  }

  .mui-zoom {
    -webkit-transform-style: preserve-3d;
    transform-style: preserve-3d;
  }

  .mui-slider .mui-slider-group .mui-slider-item img {
    width: auto;
    height: auto;
    max-width: 100%;
    max-height: 100%;
  }

  .mui-android-4-1 .mui-slider .mui-slider-group .mui-slider-item img {
    width: 100%;
  }

  .mui-android-4-1 .mui-slider.mui-preview-image .mui-slider-group .mui-slider-item {
    display: inline-table;
  }

  .mui-android-4-1 .mui-slider.mui-preview-image .mui-zoom-scroller img {
    display: table-cell;
    vertical-align: middle;
  }

  .mui-preview-loading {
    position: absolute;
    width: 100%;
    height: 100%;
    top: 0;
    left: 0;
    display: none;
  }

  .mui-preview-loading.mui-active {
    display: block;
  }

  .mui-preview-loading .mui-spinner-white {
    position: absolute;
    top: 50%;
    left: 50%;
    margin-left: -25px;
    margin-top: -25px;
    height: 50px;
    width: 50px;
  }

  .mui-preview-image img.mui-transitioning {
    -webkit-transition: -webkit-transform 0.5s ease, opacity 0.5s ease;
    transition: transform 0.5s ease, opacity 0.5s ease;
  }

  @-webkit-keyframes fadeIn {
    0% {
      opacity: 0;
    }
    100% {
      opacity: 1;
    }
  }

  @keyframes fadeIn {
    0% {
      opacity: 0;
    }
    100% {
      opacity: 1;
    }
  }

  @-webkit-keyframes fadeOut {
    0% {
      opacity: 1;
    }
    100% {
      opacity: 0;
    }
  }

  @keyframes fadeOut {
    0% {
      opacity: 1;
    }
    100% {
      opacity: 0;
    }
  }

  p img {
    max-width: 100%;
    height: auto;
  }
</style>
<script src="__PUBLIC__/xsd/js/mui.zoom.js"></script>
<script src="__PUBLIC__/xsd/js/mui.previewimage.js?v=21313123213321231132"></script>
<script>
  mui.previewImage();
</script>


<?php if(!(empty(config('shop_hours')) || (config('shop_hours') instanceof \think\Collection && config('shop_hours')->isEmpty()))): ?>
<script>
  var time_range = function (beginTime, endTime) {
    var strb = beginTime.split (":");
    if (strb.length != 2) {
      return false;
    }

    var stre = endTime.split (":");
    if (stre.length != 2) {
      return false;
    }

    var b = new Date ();
    var e = new Date ();
    var n = new Date ();

    b.setHours (strb[0]);
    b.setMinutes (strb[1]);
    e.setHours (stre[0]);
    e.setMinutes (stre[1]);

    if (n.getTime () - b.getTime () > 0 && n.getTime () - e.getTime () < 0) {
      return true;
    } else {

      mui.alert("<?php echo config('shop_hours_message'); ?>", '公告');
      $('.mui-popup-buttons').html(' ')
      $('.mui-popup-inner').css('border-radius', '13px')
      return false;
    }
  }

  var shop_hours = "<?php echo config('shop_hours'); ?>";
  var hours_arr = shop_hours.split('-');
  time_range (hours_arr[0], hours_arr[1]);

</script>
<?php endif; if(config('is_rest') == '1'): ?>
<script>
mui.alert("<?php echo config('rest_message'); ?>", '公告');
$('.mui-popup-buttons').html(' ')
$('.mui-popup-inner').css('border-radius', '13px')
</script>
<?php endif; ?>



<script>
  $(function(){
    $('.subsc').click(function(){
      // $.get("<?php echo url('index/clearusersession'); ?>", function(data){
      //   if(data.code == 1){
      //     window.location.href = "http://mp.weixin.qq.com/s/-AzpDTU7eAD24-R5QUP0wg"
      //   }
      // })
      //cookie('goodsmodel_id', $model_id);
      <?php switch(cookie('goodsmodel_id')): case "1":case "2":case "21":case "22":case "3": ?>
            mui.alert("<img src=<?php echo get_cover(config('frankserviceimg'), 'path'); ?> style='width:100%;'>", '长按扫二维码');
        <?php break; endswitch; if(!(empty($contact_qc) || ($contact_qc instanceof \think\Collection && $contact_qc->isEmpty()))): ?>
            mui.alert('<img src="<?php echo $contact_qc; ?>" style="width:100%;">', '长按扫二维码');
      <?php endif; ?>
    })


    $('.endlimit').each(function(){
      var $this = $(this);
      var stime = $this.attr('data-endtime');
      var starttime = new Date(stime.replace(/-/g,"/"))
      setInterval(function () {
        var nowtime = new Date();
        var time = starttime - nowtime;
        if(time > 0){
          var day = parseInt(time / 1000 / 60 / 60 / 24);
          var hour = parseInt(time / 1000 / 60 / 60 % 24);
          var minute = parseInt(time / 1000 / 60 % 60);
          var seconds = parseInt(time / 1000 % 60);
          $this.html("距结束还有:<span style='color:red'>"+ day + "天" + hour + "小时" + minute + "分钟" + seconds + "秒</span>");
        }

      }, 1000);
    })

    $('.hidecartbtn').each(function(){
      var id = $(this).attr('data-id')
      $('.cartbtn'+id).hide();
    })


  })
</script>

 

 <!-- <?php if(empty(\think\Cookie::get('positioninit')) || (\think\Cookie::get('positioninit') instanceof \think\Collection && \think\Cookie::get('positioninit')->isEmpty())): ?>
 <script type="text/javascript" src="https://3gimg.qq.com/lightmap/components/geolocation/geolocation.min.js"></script>
 <script>
   $(function(){
    var geolocation = new qq.maps.Geolocation("QQ6BZ-24HC6-ZAXSZ-MTZAU-5MU2J-HEFEH", "鲜果屋");
     geolocation.getIpLocation(showPosition, showErr)

   })

   function showPosition(position) {
     console.log(1111);
     $.getJSON("<?php echo url('index/cart/changecookie'); ?>", {name: 'positioninit', 'val': position.lat+','+position.lng}, function(json, textStatus) {});
  };
   function showErr() {
     console.log('定位失败');
   };
 </script>
 <?php endif; ?> -->

</body>
</html>
